package com.example.java8demo.functionDemo;

import java.util.function.Function;

/**
 * 传入参数，返回结果
 *
 * @author tianzhuang
 * @version 1.0
 * @date 2022/1/17 23:57
 */
public class FuncDemo {
    public static Integer test() {
        Function<Integer, Integer> function = o -> o * 10;
        Integer apply = function.apply(10);
        return apply;
    }
    public static void main(String[] args) {
        Integer test = FuncDemo.test();
        System.err.println(test);
    }
}
